# Contributor: Bart Ribbers <bribbers@disroot.org>
# Maintainer: Bart Ribbers <bribbers@disroot.org>
pkgname=neochat
pkgver=22.06
pkgrel=0
pkgdesc="A client for Matrix, the decentralized communication protocol"
url="https://invent.kde.org/network/neochat/"
# armhf blocked by extra-cmake-modules
# riscv64 and s390x blocked by qqc2-desktop-style
arch="all !armhf !s390x !riscv64"
license="GPL-2.0-or-later AND GPL-3.0-only AND GPL-3.0-or-later AND BSD-2-Clause"
depends="
	kirigami2
	kitemmodels
	kquickimageeditor
	qqc2-desktop-style
	qt5-qtquickcontrols
	"
makedepends="
	cmark-dev
	extra-cmake-modules
	kconfig-dev
	kcoreaddons-dev
	kdbusaddons-dev
	ki18n-dev
	kio-dev
	kirigami2-dev
	knotifications-dev
	kquickimageeditor-dev
	libquotient-dev
	qcoro-dev
	qqc2-desktop-style-dev
	qt5-qtbase-dev
	qt5-qtdeclarative-dev
	qt5-qtkeychain-dev
	qt5-qtmultimedia-dev
	qt5-qtquickcontrols2-dev
	qt5-qtsvg-dev
	samurai
	sonnet-dev
	"
source="https://download.kde.org/stable/plasma-mobile/$pkgver/neochat-$pkgver.tar.xz"
subpackages="$pkgname-lang"
options="!check" # No tests

build() {
	cmake -B build -G Ninja \
		-DCMAKE_BUILD_TYPE=RelWithDebInfo \
		-DCMAKE_INSTALL_PREFIX=/usr
	cmake --build build
}

package() {
	DESTDIR="$pkgdir" cmake --install build
}

sha512sums="
d7f3776620592f509f9db42c5b8118c7c5d6f11ad152502a36bd49c8aa56bf3b6c0056ec1dfc4268002b6c035926aee6e9e835de271e27ebbfc2bacda218d13e  neochat-22.06.tar.xz
"
